
USE [vudu]
GO
CREATE PROCEDURE [dbo].[VerificarEstudianteExpediente]
@expediente VARCHAR(10),
@escuela INT
AS
BEGIN
	SET NOCOUNT ON;
	
	select es.noExpediente
from Escuela e, EscuelaEstudiante ee, Estudiante es
where e.id_escuela = ee.fk_Escuela and es.id_estudiante = ee.fk_Estudiante
and e.id_escuela = @escuela and es.noExpediente = @expediente;
END;

SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

